home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part2 / 15650 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.2 KB  |  30 lines

  1. Newsgroups: comp.lang.c
  2. Path: netcom.com!bnelson
  3. From: bnelson@netcom.com (Bob Nelson)
  4. Subject: Re: saving system()'s output to a C variable?
  5. Message-ID: <bnelsonDq5Ep3.Lo3@netcom.com>
  6. Organization: a computer running Linux
  7. X-Newsreader: TIN [version 1.2 PL2]
  8. References: <96104.233554U61441@uicvm.uic.edu> <4l5dtg$9d2@eccdb1.pms.ford.com>
  9. Date: Sat, 20 Apr 1996 06:43:51 GMT
  10. Sender: bnelson@netcom8.netcom.com
  11.  
  12. On 18 Apr 1996 12:52:00 GMT, Mark J. Bobak wrote:
  13. >> In article <96104.233554U61441@uicvm.uic.edu>,
  14. >> Sikander Waheed  <U61441@uicvm.uic.edu> wrote:
  15. >> >  Is it possible to save the output of the system() command to
  16. >> >a C variable? 
  17.  
  18. >> No, not exactly.  You can use popen() to open a stream and read the output
  19. >> of the command from the stream into a c variable.
  20.  
  21. Please remember that this is a group strictly devoted to the C programming
  22. language and popen() has absolutely no relevance whatsoever to Standard C.
  23.  
  24. -- 
  25. =============================================================================
  26.           Bob Nelson: Dallas, Texas, U.S.A.  -  bnelson@netcom.com
  27.       Linux for fun, M$ for $$$...and the NFL for what really counts!
  28. =============================================================================
  29.  
  30.